<template>
  <div id="app">
    <button @click="count--" v-show="count > 0">上一页</button>
    <div>
      <img :src="list[count].src" alt="" />
    </div>
    <button @click="count++" v-show="count < list.length - 1">下一页</button>
  </div>
</template>

<script setup lang="ts">
import { ref } from "vue";
import URL1 from "./imgs/11-00.gif";
import URL2 from "./imgs/11-01.gif";
import URL3 from "./imgs/11-02.gif";
import URL4 from "./imgs/11-03.gif";
import URL5 from "./imgs/11-04.png";
import URL6 from "./imgs/11-05.png";

let count = ref(0);

const list = ref([
  { src: URL1 },
  { src: URL2 },
  { src: URL3 },
  { src: URL4 },
  { src: URL5 },
  { src: URL6 },
]);
</script>

<style></style>
